package com.project.web.common.utils.exportView.view;

/**
 * pdf视图
 * Created by yqh on 2017/2/13.
 */
//public class PdfView extends AbstractView {
public class PdfView  {

//    private String filename;
//
//    public PdfView(String filename) {
//        super();
//        this.setContentType("application/pdf");
//        this.filename = filename;
//    }
//
//    @Override
//    protected void renderMergedOutputModel(Map<String, Object> map, HttpServletRequest httpServletRequest, HttpServletResponse httpServletResponse) throws Exception {
//        if (filename != null) {
//            OutputStream os = httpServletResponse.getOutputStream();
//            InputStream is = new FileInputStream(filename);
//            int len = -1;
//            byte[] arr = new byte[1024];
//            while ((len = is.read(arr)) != -1) {
//                os.write(arr, 0, len);
//            }
//            is.close();
//        }
//    }
}
